#include<stdio.h>

int AddToTop(int top)
{
    int result = 0;
    for(int i = 0; i <= top; i++)
    {
        result += i;
    }
    return result;
}

int main()
{
    int top = 100;
    int result = 0;
    
    result = AddToTop(top);
    printf("result: %d\n", result);
    return 0;
}
